package brwarner.game 
{
	import flash.events.Event;
	import flash.events.EventDispatcher;
	/**
	 * ...
	 * @author Brook Jensen
	 */
	public class God extends EventDispatcher
	{
		//Mana amounts
		private var _fire:Number, _water:Number, _air:Number, _ground:Number;
		
		public function God( f:Number, w:Number, a:Number, g:Number ) 
		{
			//Setup the initial mana values
			_fire = f; _water = w; _air = a; _ground = g;
		}
		
		public function set Fire( v:Number ):void
		{
			_fire = v;
			if ( _fire < 0 ) _fire = 0;
			dispatchEvent( new Event("onManaChanged") );
		}
		public function set Water( v:Number ) : void
		{
			_water = v;
			if ( _water < 0 ) _water = 0;
			dispatchEvent( new Event("onManaChanged") );
		}
		public function set Air( v:Number ) : void
		{
			_air = v;
			if ( _air < 0 ) _air = 0;
			dispatchEvent( new Event("onManaChanged") );
		}
		public function set Ground( v:Number ) : void
		{
			_ground = v;
			if ( _ground < 0 ) _ground = 0;
			dispatchEvent( new Event("onManaChanged") );
		}
		
		public function get Fire( ) : Number
		{
			return _fire;
		}
		public function get Water( ) : Number
		{
			return _water;
		}
		public function get Air( ) : Number
		{
			return _air;
		}
		public function get Ground( ) : Number
		{
			return _ground;
		}
		
	}

}